<?php
declare (strict_types = 1);

namespace app\index\controller;
use think\facade\View;
use think\facade\Db;
use think\captcha\facade\Captcha;

use app\common\model\Sms as SmsModel;


class Sms extends Base
{

    public function send(){
        $param = input('param.');
        if( !isset($param['mobile']) || $param['mobile'] == ''){ return dyajaxReturn(0,'手机号码不能为空'); }
        $mobile = $param['mobile'];
        $type = $param['type'];

        $SmsModel = new SmsModel();
        $res = $SmsModel->send($mobile,$type);
        return dyajaxReturn($res['code'],$res['msg'],$res['data']);
    }


}
